#include<stdlib.h>
int main()
{
    int a,b;
    long c=1;
    scanf("%d",&b);
    for(a=1;a<=b;a++)
    {
        c*=a;
    }
    printf("%d",c);
    return 0;
}
